package cn.itsource.system.mapper;


import cn.itsource.system.domain.Employee;
import cn.itsource.system.domain.Role;
import cn.itsource.system.query.EmployeeQuery;

import java.util.List;

/**
 * Mapper接口：菜单Employee
 */
public interface EmployeeMapper {
    /**
     * 查询所有
     * @return
     */
    List<Employee> findAll();

    /**
     * 查询单个
     * @param id
     * @return
     */
    Employee findOne(Long id);

    /**
     * 添加
     * @param employee
     */
    void add(Employee employee);

    /**
     * 修改
     * @param employee
     */
    void update(Employee employee);

    /**
     * 删除
     * @param id
     */
    void delete(Long id);

    /**
     * 批量删除
     * @param ids
     */
    void patchDel(Long[] ids);

    /**
     * 分页+高级查询
     * @param employeeQuery
     * @return
     */
    List<Employee> queryPage(EmployeeQuery employeeQuery);

    void delEmpRole(Long id);

    void addEmpRole(Employee employee);

    List<Role> getEmpRoles(Long id);
}
